<%@ page language="java" import="java.util.*" pageEncoding="utf-8"%>
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core"%>
<%
String path = request.getContextPath();
String basePath = request.getScheme()+"://"+request.getServerName()+":"+request.getServerPort()+path+"/";
%>

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
  <head>
    <base href="<%=basePath%>">
    <!-- 宣传委员 -->
   <title>班级活动报名管理</title>
    <meta name="viewport" content="width=device-width,initial-scale=1" />
    <meta http-equiv="pragma" content="no-cache">
	<meta http-equiv="cache-control" content="no-cache">
	<meta http-equiv="expires" content="0">
	<link rel="stylesheet" type="text/css" href="css/f/navs.css">
	<link rel="stylesheet" type="text/css" href="css/f/default.css">
	<link rel="stylesheet" type="text/css" href="css/f/assignment.css"/>
	<script src="js/jquery.min.js"></script>
	<script type="text/javascript" src="js/f/jskey_calendar.js"></script>
	<script src="js/f/default.js"></script>
</head>

<body>
	<div class="all">
		<jsp:include page="/nav.jsp"></jsp:include>
        <div class="rightall float-left">
  			<input type="hidden" value="${error_msg }" name="errorMsg" />
        	 <div class="already">
	            <div class="already-title">
	                <div class="left float-left">班级活动报名信息</div>
	            </div>
	       		 <table>
	  				<tr class="tr-style-head">
		  				<td>活动标题</td>
		  				<td>学生姓名</td>
		  				<td>报名时间</td>
		  				<td>审核状态</td>
	  					<td>操作</td>
	  				</tr>
	  				<c:forEach  var="ae" items="${ae}">
		  				<tr class="tr-style">
			  				<td>${ae.activityTitle }</td>
			  				<td>${ae.stuName }</td>
			  				<td>${ae.createTime }</td>
			  				<td>
			  					<c:if test="${ae.enrollState==1 }"><span  class="a-color-blue">审核中</span></c:if>
			  					<c:if test="${ae.enrollState==2 }">已通过</c:if>
			  					<c:if test="${ae.enrollState==3 }"><span  class="a-color-red">已拒绝</span></c:if>
			  				</td>
			  				<c:if test="${ae.enrollState==1 }">
				  				<td>
				  					<a href="cadre/enrollState.do?id=${ae.enrollId }&state=2" class="a-color-blue" onclick="return aler('确认通过报名');">通过</a>
				  					<a href="cadre/enrollState.do?id=${ae.enrollId }&state=3" class="a-color-red" onclick="return aler('确认拒绝报名');">拒绝</a>
				  				</td>
			  				</c:if>
			  				<c:if test="${ae.enrollState!=1 }">
				  				<td>
				  					<a href="javascript:void(0)" style="color:grey;">通过</a>
				  					<a href="javascript:void(0)" style="color:grey;">拒绝</a>
				  				</td>
			  				</c:if>
		  				</tr>
	  				</c:forEach>
	  			</table>
                <c:if test="${pages > 1 }">
	            	<div class="previous">
	              	 		<c:if test="${pageNo > 1}"> <a href="cadre/activityEnroll.do?pageNo=${pageNo-1 }">上一页</a> </c:if>
	              	 		<c:forEach var="p" begin="1" end="${pages }" step="1">
	              	 		<c:if test="${p==pageNo }">
	                   			<span style="font-size:18px;color:#446ee6;">&nbsp;${p}&nbsp;</span>
	                   		</c:if>
	                   		<c:if test="${p!=pageNo }">
	                   			<a href="cadre/activityEnroll.do?pageNo=${p }" >&nbsp;${p}&nbsp;</a>
	                   		</c:if>
	               		 </c:forEach>
	                	<c:if test="${pageNo < pages}"><a href="cadre/activityEnroll.do?pageNo=${pageNo+1 }">下一页</a></c:if>
	                </div>
               </c:if>
       		 </div>
       	</div>	
     </div>		
  </body>
</html>
